y=0;
z=1;
echo([]);
echo([let(x=2) 1]);
echo([let(x=2) x]);
echo([let(x=2) x]);
echo([if(y) 1]);
echo([if(z) 1]);
echo([for(x=[y,z]) x]);
echo([for(x=[y:z]) x]);
echo([for(x=[0:-1:10]) x]);
echo([for(x=[10:1:0]) x]);
echo([for(x=[0:10]) x]);
echo([for(x=[0:3],y=[10:13]) [x,y]]);
echo([for(x=[0:3]) for(y=[10:13]) [x,y]]);
echo([for(x=[0:3]) [ for(y=[10:13]) [x,y] ] ]);
echo([for(x=[0:3]) if(x==1) [ for(y=[10:13]) if(y != 11) [x,y] ] ]);
a = [for(x=[0:3]) [ for(y=[10:13]) [x,y] ] ];
echo(a);
echo([ for (a = "") a ]);
echo([ for (a = "a\u2191b\U01f600") a ]);
echo([ for(i=a) for(j=i) j ]);
echo([ for(i=a) for(j=i) for(k=j) k ]);
echo([ for(i=a,j=i) j ]);
echo([ for(i=a,j=i,k=j) k ]);
echo([ for (a=[0:1]) a]);
echo([ for (a=[0:1]) if (true) a]);
echo([ for (a=[0:1]) if (true) if (true) a]);
echo([ for (a=[0:1]) for (b=[a:2]) [b,a]]);
echo([ for (a=[0:1]) if (true) for (b=[a:2]) [b,a]]);
echo([ for (a=[0:1]) if (true) if (true) for (b=[a:2]) [b,a]]);
echo([ -1, for (a = [0:1:3]) a, for (b = [3:-1:0]) b, -1 ]);
echo([ for (a = [2:3]) a * 2, for (a = [5:9]) if ((a % 2) == 0) [ a, a + 1 ] , -1 ]);
echo([ for (a = [0,1,2]) if (a == 1) "-" else "+" ]);
echo([ for (a = [0,1,2]) if (a > 0) if (a == 1) "A" else "B" ]);
echo([ for (a = [0,1,2]) if (a > 0) if (a == 1) "A" else "B" else "-" ]);
echo([ for (a = [0 : 3]) if (a < 2) if (a < 1) ["+", a] else ["-", a] ]);
echo([ for (a = [0 : 3]) if (a < 2) ( if (a < 1) ["+", a] ) else ["-", a] ]);
echo([ for (a = [2 : 4]) each [ a, a*a ] ]);
function f() = [ for (a = [0 : 4]) pow(2, a) ];
echo([ each ["a", "b"], each [-5 : -2 : -9], each f(), each "c", each 42, each true ]);
echo([ for (i=2;i<=10;i=i+2) i ]);
echo([ for (i=1,n=1;i<=4;i=i+1,n=(n+i)*i) [i,n] ]);
